package com.ac.controller;

import com.ac.config.ResponseEntity;
import com.ac.service.BuildingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/building")
public class BuildingController {

    @Autowired
    private BuildingService buildingService;

    @GetMapping("/all")
    public ResponseEntity all(){
        return ResponseEntity.success(buildingService.getAll());
    }
}
